home *** CD-ROM | disk | FTP | other *** search
/ io Programmo 23 / IOPROG_23.ISO / SOFT / DOCJET.ZIP / data.z / Project Scanner.h < prev    next >
Encoding:
C/C++ Source or Header  |  1998-06-18  |  1.7 KB  |  56 lines

  1. /* Copyright (C) 1997-1998, Tall Tree Software Co.
  2.  *
  3.  * This code is provided AS-IS, with no warranty expressed or implied.
  4.  *  in no way shall Tall Tree Software Co. be held liable for damages
  5.  *  brought about by the use of this software.
  6.  */
  7.  
  8. #ifndef Project_Scanners_h
  9. #define Project_Scanners_h
  10.  
  11. /*
  12.    This header file declares all the objects you need if you are going to
  13. write a project-scanner DLL plug-in for DocJet.  Detailed instructions on
  14. how to write one of these DLL's can be found in the on-line help.  To get
  15. to it, open the table of contents (the "Contents" tab of the search
  16. window), open the "DocJet Plug-Ins" book, and double click the "Project
  17. File Scanner DLL's" topic underneath it.
  18.  
  19.    The main thing you need to do is write a function that conforms to this
  20. interface:
  21.  
  22.     extern "C" DLLEXPORT void ScanProject( const char *filename,
  23.                            FileReportFunction onFileFound );
  24.  
  25. It should search through filename, looking for potential source files
  26. within it, then call onFileFound for each of them.
  27.  
  28.     You also need to have a resource script with two string table entries
  29. that look something like this:
  30.  
  31. STRINGTABLE DISCARDABLE
  32. BEGIN
  33.     IDS_EXTENSIONS "*.mak;makefile"
  34.     IDS_NAME       "Makefile-based project"
  35. END
  36.  
  37. Where IDS_EXTENSIONS is defined to 1001 and IDS_NAME is defined to 1002.
  38.  
  39.     As with all plug-in DLL's, it should be compiled with the "Multithreaded
  40. DLL" code-generation flag.
  41.  
  42.  */
  43.  
  44. typedef void (*FileReportFunction)( const char *foundFile );
  45.  
  46. #ifndef DLLEXPORT
  47. #define DLLEXPORT _declspec(dllexport)
  48. #define DLLIMPORT _declspec(dllimport)
  49. #endif
  50.  
  51. #define PROJECT_ICON_RESOURCE_ID 1000
  52. #define PROJECT_EXTENSIONS_RESOURCE_ID 1001
  53. #define PROJECT_NAME_RESOURCE_ID 1002
  54.  
  55. #endif
  56.